home *** CD-ROM | disk | FTP | other *** search
/ HPAVC / HPAVC CD-ROM.iso / CRYPT18.ZIP / KRTT41.DOC < prev    next >
Text File  |  1993-09-13  |  9KB  |  233 lines

  1.  
  2.                      Köhntark's Recursive Tunneling Toolkit
  3.                                   Version 4.1
  4.                              Released 27 August 1993
  5.          ═════════════════════════════════════════════════════════════
  6.          1. DISCLAIMER
  7.  
  8.          The author of this toolkit is in no way responsible for any
  9.          damage that its proper or improper usage might cause.
  10.  
  11.          ═════════════════════════════════════════════════════════════
  12.          2. LICENSE?
  13.  
  14.          You are free to include this toolkit in computer viruses.
  15.  
  16.          ═════════════════════════════════════════════════════════════
  17.          3. INFO
  18.  
  19.          You don't have to read this whole document before trying to
  20.          do something with the toolkit!
  21.  
  22.          If you have never written a virus in Assembler, you can start
  23.          with the toolkit!  (well, almost!)
  24.  
  25.          Köhntark's Recursive Tunneling Toolkit is an object module
  26.          that can be linked to any virus.
  27.  
  28.          The virus should be assembled and linked with KRTT41.OBJ
  29.          using Turbo Assembler 2.0 and above.
  30.  
  31.          Using other Assemblers might cause unexpected results.
  32.  
  33.          The toolkit, when called will try find the address of DOS's
  34.          real int 21h / 2Ah / 13h.
  35.  
  36.          The output code returned will depend on the results found by
  37.          the toolkit.
  38.  
  39.          KRTT41.OBJ is truly a NO-FRILLS object module. You need
  40.          nothing to use it. It is a simple, 'plug and play' item; just
  41.          save the registers, call it and act depending upon the
  42.          output.
  43.  
  44.          Unlike other tunneling routines KRTT DOES NOT use Interrupt 1
  45.          to trace through the current interrupts, as this technique
  46.          can be easily disabled by any decent resident AV utility.
  47.  
  48.          ═════════════════════════════════════════════════════════════
  49.          4. What the hell is tunneling?
  50.             Why use this?
  51.  
  52.          A quick explanation: Antivirus system monitoring software are
  53.          Terminate and Stay Resident (TSR) programs that remain in
  54.          memory and hook or capture INT 21h / 2Ah / 13h and other
  55.          vital system interrupts.
  56.          
  57.          These programs monitor all calls made to these interrupts for
  58.          'suspicious' or 'virus-like' behaviour. An example would be
  59.          unauthorized writing to a file thought INT 21h, function 40h.
  60.  
  61.          These programs ensure that all viruses not using any
  62.          tunneling or stealth routines are detected when trying to
  63.          infect or remain resident in memory.
  64.  
  65.          Some examples of such programs will even monitor their own
  66.          code to ensure they are not removed from memory or their
  67.          INT 21h handler is not replaced by other programs.
  68.  
  69.  
  70.          KRTT41 will get the DOS's original INT 21h / 2Ah / 13h, in
  71.          most cases, and can turn your virus into a 'smart' one by
  72.          warning about the possibility of strange AV software present
  73.          in memory.
  74.  
  75.          Once DOS's original interrupts are found you can call them
  76.          directly to memory freely, bypassing any AV software present
  77.          in memory and infecting other files right through their
  78.          protection!
  79.  
  80.          The ability to locate DOS's original INT 13h is provided
  81.          by KRTT to implement potentially destructive code.
  82.          (None of the examples contain such code.)
  83.  
  84.          You could also use the original int 21h to allocate/free
  85.          memory and disable any software present in memory.
  86.  
  87.          Such scenarios are possible but they have not tested fully,
  88.          so no claims can be made.
  89.  
  90.          KRTT41's strength lies in a recursive nature which allows
  91.          tracing and scanning through multiple hooked INT 21h's.
  92.  
  93.          You can load multiple non-conflicting system monitoring
  94.          antivirus programs and KRTT41 will go through them!
  95.  
  96.          Be it 1 or 6 - admittedly a ridiculous situation - it won't
  97.          make a difference.
  98.  
  99.          KTTR41 is very small due to its recursive nature. And
  100.          it is fast since it uses no memory locations for data
  101.          storage; all the operations are done directly in the CPU
  102.          registers.
  103.  
  104.          KTTR41 is fully compatible with Trident's Polymorphic Engine
  105.          Version 1.4 and future polymorphic Engines.
  106.  
  107.          Such compatibility is assured as long as KRTT 4.1 is linked
  108.          before any Polymophic Engine.
  109.  
  110.          Note: See YB-1.ASM for TpE 1.4 linkage demonstration.
  111.  
  112.          ═════════════════════════════════════════════════════════════
  113.          5. USAGE:
  114.  
  115.          You need the following at the beginning of your program:
  116.  
  117.          extrn TUNNEL:near
  118.          ~~~~~~~~~~~~~~~~~
  119.          then call anytime during program execution (preferably at the
  120.          start):
  121.  
  122.          call TUNNEL
  123.          ~~~~~~~~~~~
  124.          Then store the address of the found INT 21h in a double word
  125.          location within your virus.
  126.          
  127.          You can then call the real INT 21h doing a CALL DWORD PTR to
  128.          such location.
  129.  
  130.          All this is shown in YB-1.ASM and YB-2.ASM
  131.  
  132.          TUNNEL 4.1 procedure usage:
  133.  
  134.          INPUT:  bp=01                 => Search for original INT 2Ah
  135.                  bp=02                 => Search for original INT 13h
  136.                  Any other value in bp => Search for original INT 21h
  137.          (you MUST save any necessary registers)
  138.  
  139.          OUTPUT: ah=00  Not found
  140.                  ah=01  Found!
  141.                  ah=02  Int 21h/ 2hA /13h Not Hooked
  142.                  ah=03  DOS internal interrupts are hooked (search for
  143.                  int 21h / 2Ah / 13h not conducted)
  144.  
  145.          If found:
  146.                  dx=  INT 21h / 2Ah / 13h SEGMENT
  147.                  di=  INT 21h / 2Ah / 13h OFFSET
  148.                  al=  RECURSION DEPTH
  149.  
  150.                  REGISTERS DESTROYED: ax,bx,cx,dx,di,bp,es
  151.  
  152.  
  153.          At infection time you must add 248 (decimal) bytes to the
  154.          virus size. (see YB-1.ASM, YB-2.ASM)
  155.  
  156.          ASSEMBLE: tasm /m <yourvirus>
  157.  
  158.          LINK:    tlink /x /t <yourvirus> krtt41.obj
  159.  
  160.          or
  161.  
  162.          LINK:    tlink /x /t <yourvirus> krtt41.obj <poly-engine>.obj
  163.  
  164.          ═════════════════════════════════════════════════════════════
  165.          6. TESTING:
  166.  
  167.          The toolkit has been tested with a reasonable amount of
  168.          hardware and software.
  169.  
  170.          Success for, loaded in the following order:
  171.  
  172.             DOS 5.00 (high) + Vshield 106 (McAfee)
  173.             DOS 5.00 (high) + Vshield + Vshield 106
  174.             DOS 5.00 (high) + Virstop (FPROT 2.09)
  175.             DOS 5.00 (high) + TBdriver + TBfile  (TBAV 6.03)
  176.  
  177.             DOS 5.00 + Vshield (McAfee) + Virstop
  178.             DOS 5.00 + Vshield (McAfee) + Virstop
  179.                      + TBdriver + TBfile !!!!
  180.  
  181.          You can switch the order of the first 2. Tbfile won't let
  182.          anything load if it is not loaded last.
  183.  
  184.             DOS 5.00 (high) + QEMM 6.0 (high) + Vshield 106  (McAfee)
  185.             DOS 5.00 (high) + QEMM 6.0 (high) + Vshield + Vshield 106
  186.             DOS 5.00 (high) + QEMM 6.0 (high) + Virstop (FPROT 2.09)
  187.             DOS 5.00 (high) + QEMM 6.0 (high) + TBdriver + TBfile
  188.                               (TBAV 6.03)
  189.  
  190.             DOS 5.00 (high) + QEMM (high) + Vshield (McAfee) + Virstop
  191.             DOS 5.00 (high) + QEMM (high) + Vshield (McAfee) + Virstop
  192.                             + TBdriver + TBfile !!!!
  193.  
  194.          KRTT is compatible MS-DOS and IBM DOS versions ranging from
  195.          3.1 to 6.0
  196.  
  197.          The above results can be also reproduced against the
  198.          following:
  199.  
  200.             QEMM 7.0
  201.             HIMEM.SYS
  202.             EMM386.SYS
  203.             VDEFEND (PCTOOLS 7.1)
  204.             Central Point Antivirus  1.3
  205.             Secure 2.35 (Mark Washburn)
  206.             Virex 2.8   (Ross Greenburg)
  207.             Flushot+ V1.84
  208.             Martin's Virus Trap V182 (Russia)
  209.             Antiviral Toolkit Pro 1.06 (Russia) (see YB-1 and YB-2)
  210.             Turbo Debugger 2.0
  211.             Watchdog (Leprechaun Software)
  212.             VSAFE (CPAV / MSAV)
  213.  
  214.          Note that some of the above software developers costs $50+,
  215.          all circunvented by a free 248 byte program!
  216.  
  217.          ═════════════════════════════════════════════════════════════
  218.          8. Final Notes From the Depths of HELL
  219.  
  220.          If you have any questions or doubts please look at the demo
  221.          viruses , YB-1.ASM, YB-2.ASM or the KTTRDEMO.ASM program.
  222.  
  223.          Any questions or comments are appreciated
  224.  
  225.          I can be contacted at CIS (Crypt InfoSystems) BBS.
  226.          and VX BBS's through out the world.
  227.  
  228.          Not illegal yet!
  229.  
  230.          Köhntark
  231.  
  232.          ÜWEUHL KÜMPKAAH!
  233.